package com.bdqn.crm.controller;

import com.bdqn.crm.pojo.SysUser;
import com.bdqn.crm.service.SysUserService;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.*;

@RestController
public class SysUserController {
    @Resource
    private SysUserService sysUserService;
    @RequestMapping(value = "/getUser",method = RequestMethod.GET)
    public SysUser getUser(Long usrId){
        return sysUserService.getUser(usrId);
    }

//    @GetMapping(value = "/users")
//    public List<SysUser> findAllUsers(){
//        List<SysUser> list = sysUserService.findAllUsers();
//        return list;
//    }
//    @GetMapping("/user/{id}")
//    public SysUser getUser(@PathVariable("id")Long usrId){
//        return sysUserService.getUser(usrId);
//    }
//
//    @PostMapping("/user")
//    public void addUser(SysUser sysUser){
//         sysUserService.addUser(sysUser);
//    }
//
//    @PutMapping ("/user")
//    public void updateUser(SysUser sysUser){
//        sysUserService.updateUser(sysUser);
//    }
//
//    @DeleteMapping ("/user/{id}")
//    public void deleteUser(@PathVariable("id")Long usrId){
//        sysUserService.deleteUser(usrId);
//    }
}
